# -*- coding:utf-8 -*-
# random 模块

import random

print(random.random())

print(random.randint(1,3))

print(random.randrange(1,3))

print(random.choice('abcd'))

print(random.sample('abcdd', 2))

print(random.uniform(1,1))
print(random.uniform(1,3))

list = [1,2,3]
print(random.shuffle(list)) # None
print(list) # [1, 3, 2]

code = ''

for i in range(4):
    tmp = random.randint(0,3)
    if tmp == i:
        code += chr(random.randrange(65,91))
    else:
        code += str(random.randint(0,9))
print(code)